pp108 : loadAppPalette Method

loadAppPalette Method


Loads the AppPalette in the specified region. If no region is specified, the AppPalette loaded as a floating object. Once loaded, you can access the AppPalette using the application.appPalettes collection.

An AppPalette Definition is the same as an Application Definition. But instead of the frame node, it uses the region node.

Syntax


application.loadAppPalette(oAppPaletteDefinition, data, [fCallBackHandler])

Parameters

Parameter

Description

oAppPaletteDefinition

Required. Refers to the ApplicationDefinition XML with the region node.

data

Optional. Refers to the data to be passed to the appPalette.

fpCallbackHandler

Optional. Refers to the function to be called after the appPalette is loaded.


Return Value


Returns the AppPalette container.

Remarks


An AppPalette that is opened can use the isAppPaletteClosable() method. When called, this method should return boolean. The isAppPaletteClosable() method is called by the host application when it is being closed. If any of the AppPalettes in the application returnfalse, then the application and the AppPalettes are not closed.

Example

function showAppPalette()
{
	    application.loadAppPalette(testAppPaletteUIApplication.XMLDocument.documentElement, null);
}
<script type="cordys/xml" id="testAppPaletteUIApplication">
       <Application focus="true" display="visible">
                <id>testAppPaletteUI</id>
                <url>/cordys/wcp/test/library/ui/testcollapsible.htm</url>
                <description>App Palette UI</description>
                <caption>App Palette</caption>
                <icon>/cordys/wcp/images/license/licensemanagement.gif</icon>
                <region docked="false">rightRegion</region>
       </Application>
</script>

Applies To


application

See Also


AppPalettes, Regions